package com.itheima;

import com.example.HeaderConfig;
import com.example.MyImportSelector;
import com.example.TokenParser;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Import;

@ServletComponentScan//扫描过滤器
@SpringBootApplication
/*
SpringBootApplication默认就是扫描启动类的所在包以及子包 如果修改了就不具备默认功能 只能手动加上
 */
//@ComponentScan(basePackages = {"com.itheima", "com.example"})//不推荐性能低

//方法2
//@Import(TokenParser.class)//导入普通类

//@Import(HeaderConfig.class)//导入配置类

@Import(MyImportSelector.class)//批量导入
public class TliasXtApplication {

    public static void main(String[] args) {
        SpringApplication.run(TliasXtApplication.class, args);
    }

}
